home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1997 February / EnigmA AMIGA RUN 15 (1997)(G.R. Edizioni)(IT)[!][issue 1997-02][PLANET CD V].iso / enigma / earcd / utility / utilfile / rw2ent16.lha / Raw2Ent.rexx < prev    next >
OS/2 REXX Batch file  |  1996-11-17  |  1KB  |  49 lines

  1. /* Raw2Ent by Tamio Patrick Honma for HHU CWIS-Project
  2.    $VER:1.4.1 (14.07.96) [ARexx-Script]
  3.    $VER:1.1.2 (06.09.96) [Assembler-Routine]
  4. */
  5.  
  6. /* Change the following directory to your own directory: */
  7.  
  8. dir='CWIS:Scripts/'
  9.  
  10. /* Don't change the following code */
  11.  
  12. options results
  13. options cache
  14. parse arg source destination tag
  15.  
  16. filename=source
  17. s1=REVERSE(source)
  18. n=VERIFY(s1,':/','m')
  19.  
  20. IF n>0 THEN DO
  21.   filename=REVERSE(LEFT(s1,n-1))
  22. END
  23.  
  24. say 'Filename    = '||filename
  25. say 'Source      = '||source
  26.  
  27. IF RIGHT(destination,1)='/' | RIGHT(destination,1)=':' THEN destination=destination||filename||'.ent'
  28. ELSE destination=destination||'.ent'
  29.  
  30. say 'Destination = '||destination
  31.  
  32. tag=UPPER(tag)
  33.  
  34. IF tag='' THEN DO
  35.     IF open('env','ENV:cwis/'||filename,'r') THEN DO
  36.         tag=UPPER(readln('env'))
  37.         close('env')
  38.         say(tag)
  39.     END
  40. END
  41.  
  42. say 'starting Raw2Ent-Routine - please stand by! Timer set to '||TIME('R')
  43. address command dir||'Raw2Ent '||source||' '||destination||' '||tag
  44. say 'routine took '||TIME('E')||' seconds'
  45.  
  46. address command 'setenv cwis/'||filename||' TAG'
  47. address command 'copy env:cwis/ envarc:cwis/ all'
  48. say('ENV:'||filename)
  49.